/**
 * 角色相关
 */

import axios from "@/utils/axios";

// 查询角色列表
export const getListRole = (params) =>
  axios({
    url: "/uias-role/pageRole",
    method: "GET",
    params,
  });

// 添加|更新角色
export const addUpdateRole = (data) =>
  axios({
    url: "/uias-role/addUpdateRole",
    method: "POST",
    data,
  });

// 删除角色
export const delRole = (data) =>
  axios({
    url: "/uias-role/delRole",
    method: "POST",
    data,
  });

// 授权角色
export const authRoleMenu = (data) =>
  axios({
    url: "/uias-role/authRoleMenu",
    method: "POST",
    data,
  });

// 查询已授权菜单
export const getListRoleMenu = (data) =>
  axios({
    url: "/uias-role/listRoleMenuIds",
    method: "POST",
    data,
  });
